package com.jld.spring.aop.annotation;

import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.aspectj.lang.annotation.Pointcut;
import org.springframework.core.annotation.Order;
import org.springframework.stereotype.Component;

@Component
@Aspect
@Order(1)//切面优先级，@Order注解的value属性值越小，优先级越高
public class ValidateAspect {
    @Before("com.jld.spring.aop.annotation.LoggerAspect.pointCut()")//可以拿到从其他类中声明的切入点表达式
    public void beforeMethod(){
        System.out.println("ValidateAspect前置通知");
    }
}
